package com.uu.custom.yingbang.facade.restful.common;

import org.springframework.stereotype.Component;
import org.uu.skull.result.ResultCode;

import javax.annotation.PostConstruct;

/**
 * User : LiuKe
 * Date : 2017/09/19
 * Time : 23:28
 */

@Component
public class Code {
    public static final String SUCCESS = "000000";

    public static final String TRACKING_NUMBER_NOT_NULL = "100001";
    public static final String SELECT_TRACKING_ERROR = "100002";

    //将返回代码与信息说明存入skull框架的ResultCode中，便于自动生成Result
    @PostConstruct
    public void init() {

        ResultCode.put(SUCCESS, "成功");
        ResultCode.put(TRACKING_NUMBER_NOT_NULL, "运单号不能为空");
        ResultCode.put(SELECT_TRACKING_ERROR, "查单失败");
    }
}
